helm-charts: support pre-release suffix as well #463
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Without it eks or gke versions will not be considered as valid versions
Related to #401
What problem does this PR solve?
Helm relies on Masterminds/semver for version comparison. According to both the Helm docs and the SemVer README (see the "Checking Version Constraints" section), version ranges do not match pre-release versions unless the constraint explicitly allows them.
EKS (and GKE) Kubernetes versions always include a pre-release suffix, e.g.:
v1.34.1-eks-3025e55. So, with a constraint like>= 1.19, SemVer will not consider pre-release versions valid, so Helm rejects the chart even though the Kubernetes version is technically higher.The SemVer documentation explains that to include pre-releases in a version range, you must add a
-0suffix:>= 1.19.0-0After changing the chart’s kubeVersion to include
.0-0, Helm correctly accepted the EKS version.Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)